<template>
  <div id="app">
    <!-- <img src="./assets/logo.png"> -->
    <router-link to="Home" active-class='select'>首页</router-link>
    <router-link to="user" active-class='select'>用户页</router-link>
    <router-link to="news" active-class='select'>新闻页</router-link>
    <router-link v-for="(item,index) in dataList" :key="index" :to='"mine/"+item.name+"/"+item.age+"/"+item.sex'>个人中心</router-link>
    <router-link to='slideShow' active-class='select'>轮播图</router-link>
    <router-view/>
  </div>
</template>

<script>
export default {
  name: "App",
   data(){
        return{
            dataList:[
                {
                    name:'张三',
                    age:16,
                    sex:'boy'
                },
                 {
                    name:'李四',
                    age:14,
                    sex:'girl'
                },
                {
                    name:'老五',
                    age:20,
                    sex:'boy'
                },
                {
                    name:'马六',
                    age:18,
                    sex:'boy'
                },
                 {
                    name:'王八',
                    age:17,
                    sex:'girl'
                }
            ]
        }
    }
};
</script>

<style>
/* .router-link-active{
  color: red;
} */
.select{
  color: red;
}
</style>
